package com.shj.em.biz.sys.service;

import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.IService;
import com.shj.em.biz.sys.entity.Cd;

import java.util.List;
import java.util.Map;

/**
 * 代码项值 服务类
 *
 * @author Shen Huang Jian
 * @since 2018-07-04
 */
public interface CdService extends IService<Cd> {

    String CD_TYPE_SEX = "sex";
    String CD_TYPE_SUPPLY_TYPE = "supplyType";
    String CD_TYPE_SUPPLY_GRADE = "supplyGrade";

    String CD_TYPE_UNIT = "unit";
    String CD_TYPE_RANK = "empRank";

    String CD_RECEIPT_COMP = "receiptCompany";
    String CD_ORDER_STATUS = "orderStatus";
    String CD_ADJUST_REASON = "adjustReason";

    String CD_TYPE_EFFORT_TYPE = "effortType";

    String CD_TYPE_SHIFT = "workShift";

    String CD_TYPE_EFFORT_WEIGHTS = "workSectionWeight";

    /**
     * 分页查询
     * @return
     */
    Page<Cd> queryCdPage(Map<String, Object> params);

    List<Cd> queryCdsByType(String type);

    Long createCd(Cd cd);

    void updateCd(Cd cd);

    String getDescrByTypeAndCd(String type, String cd);
}
